let mix = require('laravel-mix');
var glob = require('glob');
/*
 |--------------------------------------------------------------------------
 | Mix Asset Management
 |--------------------------------------------------------------------------
 |
 | Mix provides a clean, fluent API for defining some Webpack build steps
 | for your Laravel application. By default, we are compiling the Sass
 | file for the application as well as bundling up all the JS files.
 |
 */

mix.js('resources/assets/js/app.js', 'public/js')
	.copy('node_modules/jquery/dist/jquery.min.js', 'public/js')
	.copy('resources/assets/js/bootstrap.min.js', 'public/js')
	.copy('resources/assets/imgs/', 'public/imgs/', false)

for(let file of glob.sync('resources/assets/js/app/*.js')) {
	mix.js(file, 'public/js/app');
}

for(let file of glob.sync('resources/assets/sass/*.scss')) {
	mix.sass(file, 'public/css');
}
